import { Goods } from "@/entity/Goods";
import { ListParams, getDefaultListParams } from "@/entity/ListParams";

export const getCartList = (
  params: ListParams<{ cartId?: number }> = getDefaultListParams()
) =>
  new Promise<Goods[]>((resolve) => {
    console.log(params);
    setTimeout(() => {
      const list: Goods[] = [
        {
          goodsId: 1,
          goodsName: "电脑",
          number: 2,
        },
      ];
      resolve(list);
    }, 1500);
  });
